package com.gy.studyonlineapp.activity;

import androidx.appcompat.app.AppCompatActivity;

import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.TextView;

import com.gy.studyonlineapp.R;
import com.gy.studyonlineapp.constants.QuestionTypeConstants;

public class AndroidQuestCategory extends AppCompatActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_java_quest_category);
        TextView button1_1 = findViewById(R.id.button1_1);
        TextView button1_2 = findViewById(R.id.button1_2);
        TextView button1_3 = findViewById(R.id.button1_3);
        button1_1.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                Intent intent = new Intent(AndroidQuestCategory.this, JavaQuestionActivity.class);
                intent.putExtra("type", QuestionTypeConstants.androidQsType1);
                intent.putExtra("question_type", QuestionTypeConstants.androidQuestion);
                startActivity(intent);
            }
        });
        button1_2.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                Intent intent = new Intent(AndroidQuestCategory.this, JavaQuestionActivity.class);
                intent.putExtra("type", QuestionTypeConstants.androidQsType2);
                intent.putExtra("question_type", QuestionTypeConstants.androidQuestion);
                startActivity(intent);
            }
        });
        button1_3.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                Intent intent = new Intent(AndroidQuestCategory.this, JavaQuestionActivity.class);
                intent.putExtra("type", QuestionTypeConstants.androidQsType3);
                intent.putExtra("question_type", QuestionTypeConstants.androidQuestion);
                startActivity(intent);
            }
        });
    }
}